add Lite profile examples#91
Conversation
Signed-off-by: notanaka <No.Tanaka@sony.com>
Signed-off-by: Nobuyuki Tanaka <No.Tanaka@sony.com>
…examples into merge-lite-example-1
JPEWdev
left a comment
There was a problem hiding this comment.
The CI with likely find many more problems once it runs. I'll admit that the output of the checks, while very through, can be difficult to interpret. If you run into trouble getting these to pass CI, let me know and I can help interpret the errors.
Overall, the structure of these documents seems fine, they just need to conform to the JSON schema and SHACL model (which is done by CI) and they should be OK
| @@ -0,0 +1,189 @@ | |||
| { | |||
| "@context": "https://raw.githubusercontent.com/spdx/spdx-3-serialization-prototype-playground/main/jsonld/spdx-3.0-context.json-ld", | |||
There was a problem hiding this comment.
This is the example context URL, the actual URL needs to be used now, which is:
"@context": "https://spdx.github.io/spdx-spec/v3.0/model/spdx-context.jsonld"| "@graph": [ | ||
| { | ||
| "type": "SpdxDocument", | ||
| "spdxId": "http://spdx.example.com/Document/1", |
There was a problem hiding this comment.
http://spdx.example.com/Document/1 is not a good example spdxId. An SPDX ID needs some universally unique identifier, and SPDX has a defined URL prefix of https://spdx.org/spdxdocs/ for the case where the producer doesn't have their own domain. Thus, your spdx ID should probably look something like:
"spdxId": "https://spdx.org/spdxdocs/08f113e9-a0b0-4482-a0ed-c4e18e5136be/Document/1"The https://spdx.org/spdxdocs/08f113e9-a0b0-4482-a0ed-c4e18e5136be/ prefix can be reused for all the other objects in this document keeping the existing scheme of appending the type and an index if you desire.
There was a problem hiding this comment.
See "Best practices for creating spdxIds for SPDX documents (and their Elements)" at https://spdx.github.io/spdx-spec/v3.1-dev/model/Core/Properties/spdxId/ (borrowed from SPDX 2.x and to be in SPDX 3.1)
| "type": "NamespaceMap", | ||
| "prefix": "lite-example", | ||
| "namespace": "http://spdx.example.com/Lite/1" | ||
| }], |
There was a problem hiding this comment.
This namespace map is not used in the document, so please remove it for clarity
There was a problem hiding this comment.
This pattern still exists in
- lite/example1-with-VEX/spdx3.0/Lite-example-1-1-with-VEX.spdx.json
- lite/example1-with-VEX/spdx3.0/Lite-example-1-3-with-VEX.spdx.json
| "http://spdx.example.com/Relationship/2", | ||
| "http://spdx.example.com/Relationship/3" | ||
| ], | ||
| "sbomType": "build" |
There was a problem hiding this comment.
Property names are always prefix by their namespace (e.g. profile) unless they are from core, so this needs to be:
"software_sbomType": [ "build" ],Also be aware that SPDX 3.0 JSON doesn't allow array eliding, so if a property has any max ordinality other than 1, it must be an array in JSON, even if it only contains one item.
There was a problem hiding this comment.
Some of these are fixed but there are still 3 instances of "software_sbomType" that is not an array.
…examples into merge-lite-example-1
…examples into merge-lite-example-1
Signed-off-by: Nobuyuki Tanaka <No.Tanaka@sony.com>
…examples into merge-lite-example-1
Signed-off-by: Nobuyuki Tanaka <No.Tanaka@sony.com>
…examples into merge-lite-example-1
Signed-off-by: Nobuyuki Tanaka <No.Tanaka@sony.com>
…examples into merge-lite-example-1
Signed-off-by: Nobuyuki Tanaka <No.Tanaka@sony.com>
…examples into merge-lite-example-1
Signed-off-by: Nobuyuki Tanaka <No.Tanaka@sony.com>
…examples into merge-lite-example-1
Signed-off-by: Nobuyuki Tanaka <No.Tanaka@sony.com>
…examples into merge-lite-example-1
Signed-off-by: Norio Kobota <norio.kobota@sony.com>
3b13c8f to
552d82e
Compare
Signed-off-by: Norio Kobota <norio.kobota@sony.com>
Signed-off-by: Norio Kobota <norio.kobota@sony.com>
Merge lite example 1
Signed-off-by: Norio Kobota <norio.kobota@sony.com>
Signed-off-by: Nobuyuki Tanaka <No.Tanaka@sony.com>
….json Co-authored-by: Arthit Suriyawongkul <arthit@gmail.com> Signed-off-by: Norio Kobota <norio.kobota@sony.com>
….json Co-authored-by: Arthit Suriyawongkul <arthit@gmail.com> Signed-off-by: Norio Kobota <norio.kobota@sony.com>
….json Co-authored-by: Arthit Suriyawongkul <arthit@gmail.com> Signed-off-by: Norio Kobota <norio.kobota@sony.com>
Co-authored-by: Arthit Suriyawongkul <arthit@gmail.com> Signed-off-by: Norio Kobota <norio.kobota@sony.com>
Co-authored-by: Arthit Suriyawongkul <arthit@gmail.com> Signed-off-by: Norio Kobota <norio.kobota@sony.com>
|
@NorioKobota do you mind to move all SPDX JSON files from The current workflow is now looking for files in |
|
@bact Sure. |
json and png: amends of relationshipType in VEX relationship is modified to amendedBy to meet specification
Signed-off-by: Norio Kobota <norio.kobota@sony.com>
|
@bact |
bact
left a comment
There was a problem hiding this comment.
Thank you. Few minor changes suggested. After this I think we are good to go.
Co-authored-by: Arthit Suriyawongkul <arthit@gmail.com> Signed-off-by: Norio Kobota <norio.kobota@sony.com>
Co-authored-by: Arthit Suriyawongkul <arthit@gmail.com> Signed-off-by: Norio Kobota <norio.kobota@sony.com>
Co-authored-by: Arthit Suriyawongkul <arthit@gmail.com> Signed-off-by: Norio Kobota <norio.kobota@sony.com>
|
Thank you so much for the review. |
|
Thank you @NorioKobota and @no-ta . I think it's pretty much all good. Now we need a maintainer to approve the validation workflow - to let it pass the validation before merge. (Note that I have removed all my suggestions that are already resolved, since they are too long, to make this PR easier to read) |
|
@bact Ah, sorry. |
|
As there were changes in validation workflow/dependencies in April 2025 (and probably also after that), we may like to rerun the check to see if it pass now. |
bact
left a comment
There was a problem hiding this comment.
software_sbomType has to be an array
| "https://spdx.org/spdxdocs/08f113e9-a0b0-4482-a0ed-c4e18e5136be/Relationship/2", | ||
| "https://spdx.org/spdxdocs/08f113e9-a0b0-4482-a0ed-c4e18e5136be/Relationship/3" | ||
| ], | ||
| "software_sbomType": "build" |
There was a problem hiding this comment.
| "software_sbomType": "build" | |
| "software_sbomType": [ | |
| "build" | |
| ] |
| "https://spdx.org/spdxdocs/08f113e9-a0b0-4482-a0ed-c4e18e5136be/Relationship/2", | ||
| "https://spdx.org/spdxdocs/08f113e9-a0b0-4482-a0ed-c4e18e5136be/Relationship/3" | ||
| ], | ||
| "software_sbomType": "build" |
There was a problem hiding this comment.
| "software_sbomType": "build" | |
| "software_sbomType": [ | |
| "build" | |
| ] |
We implemented three samples that show how to use Lite Profile.
We would appriciate your review.